<?php use_stylesheets_for_form($form) ?>
<?php use_javascripts_for_form($form) ?>

<form action="<?php echo url_for("@message_create?contestant_id=".$contestantId) ?>" method="post">
  <?php echo $form->renderGlobalErrors() ?>
  <?php echo $form['message']->renderError() ?>
  <?php isset($form['emailorqq']) and print $form['emailorqq']->renderError() ?>
  <?php isset($form['name']) and print $form['name']->renderError() ?>
  <table width="610" border="0" cellspacing="0" cellpadding="0" class="sp_right_input">
  <tr>
    <td colspan="7" width="610">
          <?php echo $form['message']->render(array('class' => 'message-textarea', 'cols' => 45, 'rows' => 5)) ?>
        </td>
      </tr>
      <tr>
        <?php if (isset($form['emailorqq']) && isset($form['name'])): ?>
          <td width="50" align="left"><span>
          <?php echo $form['name']->renderLabel('姓名：') ?>
		  </span></td>
		  <td width="80" align="left">
          <?php echo $form['name']->render(array('class' => 'password-input','size' => '8')) ?>
		  </td>
		  <td width="80" height="50" align="left"><span>
          <?php echo $form['emailorqq']->renderLabel('QQ或Email：') ?>
		  </span>
		  </td>
		  <td width="80">
		  <?php echo $form['emailorqq']->render(array('class' => 'email-input','size' => '10')) ?>
          </td>
        <?php endif ?>
		<td width="90">
		验证码：<?php echo $form['captcha']->render(array('class' => 'captcha','size' => '4')) ?>
</td>
        <td width="80" align="right">
		<?php echo $form->renderHiddenFields() ?><input name="input" type="image" style="margin:0; padding:0;" src="/images/tj_btn_80.gif"/></td>
      </tr>
  </table>
</form>
